package xj.graph2d.template;

import java.util.Map;

import xj.graph2d.shapes.RegularPolygonShape;
import xj.graph2d.shapes.ShapeConstants;

public class PolygonTemplate extends Template {

  public PolygonTemplate() {
  }

  @Override
  public void makeTemplate(Map iconMap) {
    for (int i = ShapeConstants.BOX_SHAPE; i <= ShapeConstants.OCTAGON_SHAPE; i++) {
      for (int j = ShapeConstants.NORTH; j <= ShapeConstants.WEST; j++) {
	RegularPolygonShape shape = new RegularPolygonShape(0, 0, 50, 30, i, j);
	add(new TemplateToolButton("Poly" + i + " " + j, shape, 24, 24, (i == 0 && j == 0),
	    true));
      }
    }
  }

}
